import java.util.Arrays;
import java.util.Scanner;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 东莞呵呵
 * Date:2022-03-21
 * Time:16:38
 */
public class TestDemo {
    public static void main(String[] args) {
        int arr[]=new int[5];
        Scanner scanner=new Scanner(System.in);
        System.out.println("请输入"+arr.length+"个元素");
        for (int i = 0; i < arr.length; i++) {
            arr[i]=scanner.nextInt();
        }
        Arrays.sort(arr);
        System.out.println(Arrays.toString(arr));
    }
}
